<template>
  <div class="page_space btn_space">
    <p class="title_1">单据基础信息</p>
    <input-card>
      <inputItem
        v-for="(item, index) in data1"
        :key="index"
        :title="item.key"
        :tip="item.value"
        :type="item.type"
      />
    </input-card>

    <p class="title_1">运输车辆（选填）</p>
    <input-card>
      <div class="tip_add">
        <p>暂无供应商运输车辆</p>
        <button @click="goto('/add-supplyInfo')">
          <span>添加车辆</span>
        </button>
      </div>
    </input-card>

    <p class="title_1">运输合同（选填）</p>
    <input-card class="attachment">
      <div class="title">
        <span>运输合同</span>
        <span>查看样例</span>
      </div>
      <p class="tip">支持png、jpg、jpeg</p>
      <div class="box">
        <file-upload />
      </div>
    </input-card>

    <p class="title_1">进货品种</p>
    <input-card>
      <div class="tip_add">
        <p>暂无进货品种</p>
        <button @click="goto('/add-supplyInfo')">
          <span>添加品种</span>
        </button>
      </div>
    </input-card>

    <p class="title_1">结算信息</p>
    <input-card>
      <inputItem
        title="最终售价（选填）"
        tip="请输入最终价格"
        unit="元"
        type="input"
      />
      <inputItem title="支付状态" type="radio" />
    </input-card>

    <div class="btn_wrap">
      <button class="btn">确认进货</button>
    </div>
  </div>
</template>

<script>
import fileUpload from '@/components/file-upload'
import inputCard from '@/components/input-card/card'
import inputItem from '@/components/input-card/item'
export default {
  name: 'newPurchaseList',
  components: { fileUpload, inputCard, inputItem },
  data() {
    return {
      active: 1,
      data1: [
        {
          key: '供应商',
          value: '请选择供应商',
          type: 'select'
        },
        {
          key: '手机号',
          value: '根据选择供应商自动获取',
          type: 'select'
        },
        {
          key: '进货日期',
          value: '2025-05-15',
          type: 'select'
        },
        {
          key: '进货档口',
          value: '请选择档口',
          type: 'select'
        }
      ]
    }
  }
}
</script>

<style scoped lang="scss">

// 附件
.attachment {
  .title {
    font-family: PingFang SC Regular;
    font-size: 14px;
    font-weight: normal;
    line-height: 19px;
    letter-spacing: 0px;
    /* 一级标题颜色 */
    color: #171819;
    display: flex;
    justify-content: space-between;
    span:nth-of-type(2) {
      /* 粤商通/常规蓝色 */
      color: #2163e0;
    }
  }

  .tip {
    font-family: PingFang SC Regular;
    font-size: 14px;
    font-weight: normal;
    line-height: 19px;
    letter-spacing: 0px;
    /* 大灰 */
    color: #656c74;
  }

  .box {
    padding-top: 16px;
    // padding-bottom: 14px;
    // border-width: 0 0 0.5px 0;
    // border-style: solid;
    // border-color: #ebebeb;
  }
}
</style>
